/**
 * <pre>
 * Title: 		AccessHttpNotifyServlet.java
 * Author:		linriqing
 * Create:	 	2010-12-15 上午10:06:35
 * Copyright: 	Copyright (c) 2010
 * Company:		Shenzhen Helper
 * <pre>
 */
package com.hengpeng.itfin.port;

import java.io.IOException;
import java.io.PrintWriter;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * <pre>
 * 接入系统通知接口
 * </pre>
 * @author linriqing
 * @version 1.0, 2010-12-15
 */
public class AccessHttpNotifyServlet extends  HttpServlet
{
	private static final long serialVersionUID = -6734116831415857314L;

	@Override
	protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
	{
		this.doPost(req, resp);
	}

	@Override
	protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
	{
		String rtnXml = "";
		req.setCharacterEncoding("GBK");
		resp.setContentType("text/html;charset=GBK");
	//	String message = "";
		PrintWriter out = resp.getWriter();

//		try
//		{
//			
//			message = req.getParameter(MessageConstant.MESSAGE_AGENTPORTAL_NAMING_TRANSMESSAGE);
//			logger.info("接收的数据:" + message);
//			rtnXml = servicefactory.getHttpnotifyfacade().doHttpNotify(message,
//					req.getParameter(MessageConstant.MESSAGE_AGENTPORTAL_NAMING_TRANSTYPE));
//		}
//		catch (Exception e)
//		{
//			logger.error("", e);
//		}
//
//		logger.info("返回的数据:" + rtnXml);
		out.print(rtnXml);
		out.flush();
		out.close();
	}
}
